package com.yueyang.sojourn.server.service.sojourn.order;

import com.yueyang.sojourn.server.model.po.SojournOrderEvent;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author Andy.yang
 * @version v1
 * @summary
 * @Copyright (c) 2019, YueYang Group All Rights Reserved.
 * @since 2020/3/24
 */
@Mapper
public interface SojournOrderEventMapper {
    /**
     * 创建订单事件快照
     * @param event
     * @return
     */
    int insert(SojournOrderEvent event);

    /**
     * 查询订单事件
     * @param id
     * @return
     */
    SojournOrderEvent selectByPrimaryKey(Long id);

    /**
     *  查询订单事件列表
      * @param orderId
     * @return
     */
    List<SojournOrderEvent> findByOrderId(@Param("orderId") Long orderId);
}
